package concordia.comp6231.rfmulticast;

import java.util.HashMap;

public class Message extends HashMap<String, String> {

	private static final long serialVersionUID = 1L;

	public Message() {
		super();
	}
	
	public Message(String msgString) {
		// create msg from string
	}
	
	public int getAsInt(String key) {
		int result = -1;
		try {
			result = Integer.parseInt(this.get(key));
		} catch (NumberFormatException e) {
			System.err.println("Invalid int value for key: " + key);
		}
		return result;
	}
	
	@Override
	public String toString() {
		// TODO Auto-generated method stub
		return super.toString();
	}

}
